<?php

    require_once '../../Base.php'; 

    session_start(); 

    function __autoload($c) { 
        require_once("../../../../../../../.." . $_GET["includePath"]); 
    }

    $elem = $_SESSION["list"][$_GET["id"]]; 
?>

<form method="post">

    <input type="hidden" name="id" value="<?= $elem->id() ?>" />

    <table width="100%" class="table table-striped"> 
        <?php 

            foreach ($elem->editView() as $view) { 
        ?> 
        <tr>
            <td><?= htmlspecialchars($view["header"]) ?></td> 
            <td><input type="text" name="<?= $view["name"] ?>" value="<?= $view["value"] ?>" /></td>
        </tr>
        <?php  
            } 
        ?>
    </table> 

</form>
